package com.dalin.platform.autocode.action;

import com.dalin.framework.action.StrutsTwoAction;
import com.dalin.platform.loa.service.OperateService;
import com.dalin.platform.loa.vo.LoaOperateHeaderVo;
/*****************************************************************************
 * @content: 类信息                                                                                                                                *
 * @author : 那建林                                                                                                                                 *
 * @crtDate: 2011-03-14 10:03:11                                            *
 * @modDate: 2011-03-14 10:03:11                                            *
 * @version: 1.00                                                           *
 ****************************************************************************/
public class LoaOperateHeaderAddModAction extends StrutsTwoAction{
	private OperateService operateService; // 
    private LoaOperateHeaderVo vo; // 
    private Long[] headerIdArray;
    
    
    public String execute()throws Exception {
        super.printInfo("", "===== this action begin");
        try {
    		if (headerIdArray == null) {
    			operateService.addLoaOperateHeader(vo);
    		} else {
    			operateService.addLoaOperateHeaders(
    					vo.getOperateId(), headerIdArray);
    		}
        	setResContent(true, "");
        } catch (Exception e) {
        	e.printStackTrace();
        	setResContent(e);
        }
        super.printInfo("", "===== this action end");
        return null;

    }



    public OperateService getOperateService() {
		return operateService;
	}
	public void setOperateService(OperateService operateService) {
		this.operateService = operateService;
	}
	public LoaOperateHeaderVo getVo() {
		return vo;
	}
	public void setVo(LoaOperateHeaderVo vo) {
		this.vo = vo;
	}
	public Long[] getHeaderIdArray() {
		return headerIdArray;
	}
	public void setHeaderIdArray(Long[] headerIdArray) {
		this.headerIdArray = headerIdArray;
	}
}
